﻿@model Forum.Models.GeneralPostModel

@{
    ViewBag.Title = "Index";
}

@Html.ActionLink("Create post","PostCreate","Post",new{id=Model.CategoryId},null)

<h1>@Model.CategoryName</h1>

@foreach (var post in Model.postModels)
{
   <h4>@Html.ActionLink(@post.Title,"PostDetail","Post",new{id=post.Id},null) -- @post.DatePublished</h4> 
}